package cn.cyber.wxfire.service;

import cn.cyber.wxfire.mapper.StudentMapper;
import cn.cyber.wxfire.pojo.Student;
import cn.cyber.wxfire.vo.studentCourseVo;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class StudentServer {
    @Autowired
    private StudentMapper studentMapper;

    public List<Student> queryStudentList(){
        return studentMapper.queryStudentList();
    }

    public void addStudent(Student student)
    {
        studentMapper.addStudent(student);
    }
    public void addSC(String snum,String cnum)
    {
        studentMapper.addSC(snum,cnum);
    }

    public  void updateStudent(Student student)
    {
        studentMapper.updateStudent(student);
    }
    public  void privateUpdateStudent(Student student)
    {
        studentMapper.privateUpdateStudent(student);
    }

    public void deleteStudent(String num){ studentMapper.deleteStudent(num);}

    public List<Student> findStudent(String flag,String num){return studentMapper.findStudent(flag,num);}

    public List<Student> loginStudent(Student student){return studentMapper.loginStudent(student);}

    public List<studentCourseVo> StudentCourse(String snum){return studentMapper.StudentCourse(snum);}

    public List<Student> studentCourseList(String cnum){return  studentMapper.StudentCourseList(cnum);}
}
